Skip to content

Comments

fix(ext/node): support ipv6 host in node:http#32258

Merged
bartlomieju merged 1 commit intodenoland:mainfrom
0f-0b:node-http-ipv6
Feb 23, 2026
Merged

fix(ext/node): support ipv6 host in node:http#32258
bartlomieju merged 1 commit intodenoland:mainfrom
0f-0b:node-http-ipv6

Conversation

@0f-0b
Copy link
Contributor

@0f-0b 0f-0b commented Feb 21, 2026

Closes #21864. Full reproduction of the bug:

import { once } from "node:events";
import { request } from "node:http";

await using _server = Deno.serve({ hostname: "::1" }, () => new Response());
const req = request("http://[::1]:8000").end();
const [res] = await once(req, "response");
console.log(res.statusCode); // should print `200`

Copy link
Member

@bartlomieju bartlomieju left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, could you add a unit test @0f-0b?

Copy link
Member

@bartlomieju bartlomieju left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@bartlomieju bartlomieju merged commit 12df825 into denoland:main Feb 23, 2026
110 checks passed
@0f-0b 0f-0b deleted the node-http-ipv6 branch February 23, 2026 18:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Invalid URL on IPv6 http.RequestOptions.host without square brackets

2 participants